home *** CD-ROM | disk | FTP | other *** search
/ BBS Toolkit / BBS Toolkit.iso / maximus / valmsg19.zip / VALMSG.DOC < prev    next >
Text File  |  1992-08-26  |  5KB  |  118 lines

  1.  
  2. VALMSG -- Creates validation messages from questionnaire data
  3.  
  4. Version 1.9  (8/26/92)
  5.  
  6. Written by Bob Quinlan of Austin, Texas, USA
  7. Sysop of Red October at 512-834-2593 (1:382/111)
  8.  
  9. Copyright 1992 by Bob Quinlan
  10.  
  11. Compatible with Maximus 2.00 and 2.01
  12.  
  13.  
  14. This program reads a single user's questionnaire data and generates a
  15. message from that user to the sysop containing the data.  You can change
  16. the defaults for who the message comes from, who the messages is
  17. addressed to, and what subject goes on the message.
  18.  
  19.     /Mmessagearea   Message area "number".  This must be supplied.
  20.  
  21.     /Vfile          Validation file.  This must be supplied.
  22.  
  23.     /Aareafile      Area file.  Default is AREA.DAT in the current
  24.                     directory.
  25.  
  26.     /Fusername      From username.  If this is not supplied the first
  27.                     line of the validation file will be assumed to be a
  28.                     [post] entry and the user's name will be extracted
  29.                     from it.
  30.  
  31.     /Ssubject       Subject line.  (default: Questionnaire)
  32.  
  33.     /Tusername      To username.   (default: Sysop)
  34.  
  35. You may want to supply multiple word values for /F, /S, and /T.  You can
  36. separate the words by spaces or by underscores (which will be replaced
  37. by spaces).  For example, both of these would produce the same results:
  38.  
  39.     valmsg /mper /vquest.tmp /tBob Quinlan /sHello there!
  40.  
  41.     valmsg /mper /vquest.tmp /tBob_Quinlan /sHello_there!
  42.  
  43.  
  44. There are any number of ways that VALMSG can be used.  I'll show you my
  45. questionnaire and part of my Maximus batch file as examples of one way.
  46.  
  47. Here is my questionnaire (somewhat edited for length) between the lines:
  48. -------------------------------------------------------------------------------
  49. [lightblue]Do you wish to fill out the questionnaire [[Y,n]? [green menu]yn|
  50. [choice]n[quit]
  51. [open]D:\Max\Quest.Tmp
  52. [post][lightblue]
  53. Enter your first and last name: [green ansreq clear_stacked readln]
  54. [lightblue]
  55. Enter your home phone number (including area code): [green readln]
  56.  
  57. [lightblue]Address (line 1 of 3): [green readln]
  58. [lightblue]Address (line 2 of 3): [green ansopt readln]
  59. [lightblue]Address (line 3 of 3): [green readln]
  60. [lightcyan][ansreq][open]Nul
  61. Thank you for filling out the questionnaire!
  62.  
  63. When you log off the system will automatically generate a message from
  64. you to the sysop containing your questionnaire answers.
  65.  
  66. [lightblue enter]
  67. -------------------------------------------------------------------------------
  68.  
  69. You could run VALMSG from a MECCA, but I like to run it after the user
  70. has logged off.  Here is the piece of my Maximus batch file that does
  71. the job:
  72.  
  73. if not exist quest.tmp goto noquest
  74.     valmsg /mper /vquest.tmp /tBob Quinlan
  75.     type quest.tmp >>quest.log
  76.     del quest.tmp
  77. :noquest
  78.  
  79. If QUEST.TMP exists VALMSG is run to process it.  Then the TYPE command
  80. appends QUEST.TMP onto the end of the permanent QUEST.LOG file and
  81. QUEST.TMP is deleted.
  82.  
  83.  
  84. VALMSG returns ERRORLEVEL 0 after a successful run.  ERRORLEVEL 1 is
  85. returned to indicate an error.
  86.  
  87. NOTICE:  You may use, copy, and distribute this program freely as long
  88. as you insure that both the executable and the documentation (.DOC)
  89. files are included in the distribution package.  The source code does
  90. not need to be included.  You may modify this program and document, so
  91. long as reasonable credit is given to the original author if a
  92. substantial portion of the original remains intact.  The author is not
  93. responsible for any losses which may occur either directly or indirectly
  94. as a result of using this program.
  95.  
  96. This program uses the Squish MsgAPI and the Maximus structures written
  97. by Scott J. Dudley.  "Squish" is a trademark of Scott J. Dudley.
  98.  
  99. HISTORY:
  100. Version 1.9   (8/26/92) -- Fixed a problem with handling multiple-word
  101.                            parameters.
  102. Version 1.8   (8/25/92) -- Added the ability to pass multiple-word
  103.                            parameters using spaces.
  104. Version 1.7   (8/10/92) -- Provided additional documentation and
  105.                            examples of how to use the program.  No
  106.                            code changes.
  107. Version 1.6   (6/03/92) -- Added *.MSG support.  /M is now the "number"
  108.                            for the area, not its path.  You may need to
  109.                            use the /A switch if AREA.DAT is not in the
  110.                            current directory.
  111. Version 1.5   (5/26/92) -- Use _fsopen instead of local s_fopen.
  112. Version 1.4   (5/13/92) -- Added file sharing.
  113. Version 1.3   (4/23/92) -- Zero-out headers.  Cleaned up docs.
  114. Version 1.2   (4/18/92) -- Extract username properly from data.
  115. Version 1.1   (4/17/92) -- Added switches.
  116. Version 1.0   (4/15/92) -- Original release.  Written in Borland C.
  117.  
  118.